package cn.broadsense.biz.bo;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * 数据事项对象
 *
 * @author: pengxin
 * @create: 2024-09-12 14:28
 * @Version 1.0
 **/
@ApiModel(value = "DataItemBo", description = "数据事项对象")
@Data
public class DataItemBo implements Serializable {

    private static final long serialVersionUID = -4872783847627410638L;

    @ApiModelProperty(value = "事项编码")
    @NotBlank(message = "事项编码不能为空")
    private String itemCode;

    @ApiModelProperty(value = "采集人员ID")
    @NotNull(message = "采集人员ID不能为空")
    private Long collectUserId;

    @ApiModelProperty(value = "采集人员名称")
    @NotBlank(message = "采集人员名称不能为空")
    private String collectUserName;

    @ApiModelProperty(value = "事项描述")
    private String itemDesc;

    @ApiModelProperty(value = "设备ID")
    @NotNull(message = "设备不能为空")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long channelId;

    @ApiModelProperty(value = "模板ID")
    @NotNull(message = "模板不能为空")
    private Long templateId;



}
